The present invention relates to color image processing method and apparatus suitable for electronic imaging systems such as video cameras or digital cameras and, more particularly, to method of and apparatus for improving the dynamic range.
It may happen a case of imaging a scene, in which very bright and very dark parts coexist, for instance the face of a person in a room with a window on the back, with an electronic imaging system and displaying this image on a monitor or outputted from a printer. In this case, such a phenomenon as losing of very bright parts and squeezing of very dark parts occurs, so that it becomes impossible to reduce detailed data which must have been obtained with an imaging element of an electronic imaging system. This phenomenon stems from the fact that the dynamic range of an image output system such as a monitor or a printer is narrower than the dynamic range of the image outputted from the electronic imaging system.
Heretofore, various methods have been proposed for reducing the above loss of detail data. As an example, Japanese Patent No. 2951909 discloses gradation compensation apparatus and method for an imaging system, in which an input image is divided into a plurality of blocks like a square grating, the average brightness of each block is computed, and gradation compensation is made for each division region based on the computed average brightness.
According to the Japanese Patent No. 2951909, however, the division of the input image into regions is made based on the average brightness of the block. This means that, for instance, when a texture A, in which the brightness is changed stepwise in a narrow brightness range as shown in FIG. 19(a), and a texture B, in which the brightness is changed stepwise in a broad brightness range as shown in FIG. 19(b), are adjacent to each other, the two textures are regarded to be in the same region, and the same gradation compensation curve is thus used for the gradation compensation. Therefore, when the gradation compensation curve is preset to be best for the texture A, it may result in the losing of very bright parts of the texture B and squeezing of very dark parts of the same texture. On the other hand, when the gradation compensation curve is preset to be best for the texture B, it may become impossible to reproduce the stepwise brightness changes in the texture A.
The inventors earlier proposed an automatic dynamic range compression method, in which an input image is divided into a plurality of regions, and a peculiar density conversion process to each region is executed. In this method, the texture of the input image is analyzed, and the regions are determined based on the result of the analysis (Japanese Patent Application No. 11-333205). This automatic dynamic range compression method has an advantage that it can reduce loss of useful data compared to the prior art method.